amends "../snippetTest.pkl"

examples {
  ["read env variable"] {
    read("env:NAME1")
    read("env:NAME2")
    module.catch(() -> read("env:OTHER"))

    read?("env:NAME1")
    read?("env:NAME2")
    read?("env:OTHER")
  }

  ["read external property"] {
    read("prop:name1")
    read("prop:name2")
    module.catch(() -> read("prop:other"))

    read?("prop:name1")
    read?("prop:name2")
    read?("prop:other")
  }

  ["read file"] {
    read("read.pkl")
    module.catch(() -> read("other.txt"))
    read?("read.pkl")
    read?("other.txt")
  }

  ["read non-allowed resource"] {
    module.catch(() -> read("forbidden:resource"))
    module.catch(() -> read?("forbidden:resource"))
  }
}
